package com.tjk.crawler.controller.system;


import com.tjk.crawler.base.entity.Result;
import com.tjk.crawler.service.system.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author :  tangjiakai
 * @date :  Create in 2023/6/11 10:36
 * @description : 用户相关controller
 */
@RestController
@RequestMapping("/web/user")
public class UserController {

    @Autowired
    UserService userService;

    @PostMapping("/isValidUser")
    public Result isValidUser(
            @RequestParam("userName") String userName,
            @RequestParam("password") String password) {
        return userService.isValidUser(userName, password);
    }

}
